#pragma once

#include "Projectile.h"

class Bullet : public Projectile{
	/* Inherited 
	protected:
	float m_speed;
	float m_scale;
	float m_rotation;
	Texture m_Texture;
	public:
	PhysicObject m_PhysicObject;
	*/
private:

public:
	Bullet(){};
	~Bullet(){};

	void Initialize(LPCWSTR a_fileName){
		m_Texture.initialize(a_fileName);
	};
	void Set_Data(V2DF a_position, V2DF a_velocity, float a_scale, float a_rotation, float a_speed){
		m_PhysicObject.m_position.set(a_position.x, a_position.y);
		m_PhysicObject.m_velocity.set(a_velocity.x, a_velocity.y);

		m_speed = a_speed;
		m_scale = a_scale;
		m_rotation = a_rotation;
	};
	void Update(){
		m_PhysicObject.m_velocity.normalize();
		m_PhysicObject.m_velocity.multiply(m_speed);
	};
	void Draw(){
		m_Texture.draw(V2DF(m_PhysicObject.m_position.x, m_PhysicObject.m_position.y), m_rotation, m_scale, true);
	};
	void Release(){
		m_PhysicObject.Release();
	};
};